<extend name="Public:base" />
<block name="title">食堂档口管理</block>
<block name="content">
    <div class=" ace-save-state" id="breadcrumbs">
        <div class="page-header">
            <h1>订单管理
                <small><i class="ace-icon fa fa-angle-double-right"></i>未提交订单档口列表</small>
            </h1>
        </div>
        <!-- /.ace-settings-container -->
        <div class="page-content col-xs-11">
            <div class="row">
                <div class="col-xs-12">
                    <div class="col-xs-3" style="padding: 0;margin-bottom: 10px;margin-top: 10px">
                        <div class="input-group">
                            <span class="input-group-addon"><i class="fa fa-calendar-times-o"></i></span>
                            <input type="text" id="id-date-picker-1" value="<?php echo $order_date?>" class="form-control date-picker search-query" data-date-format="yyyy-mm-dd" placeholder="选择日期">
                            <span class="input-group-btn">
                                <button onclick="gogogo()" type="button" class="btn btn-inverse btn-white">
                                    <span class="ace-icon fa fa-search icon-on-right bigger-110"></span>
                                    查询
                                </button>
                            </span>
                        </div>
                    </div>
                    <!-- PAGE CONTENT BEGINS -->
                    <div class="row">
                        <div class="col-xs-12">
                            <table id="simple-table" class="table  table-bordered table-hover">
                                <thead>
                                <tr>
                                    <th class="center">档口序号</th>
                                    <th class="detail-col center">档口名称</th>
                                    <th class="center">所属食堂</th>
                                    <th class="hidden-480 center">联系人</th>
                                    <th class="hidden-480 center">联系电话</th>
                                </tr>
                                </thead>
                                
                                <tbody>
                                <?php if(!empty($memberList)){?>
                                <?php foreach($memberList as $k=>$l){?>
                                <tr>
                                    <td class="center"><?php echo $l['member_id'];?></td>
                                    <td class="center"><?php echo $l['window_name'];?></td>
                                    <td class="center"><?php echo $l['canteen_name'];?></td>
                                    <td class="hidden-480 center"><?php echo $l['window_contact_name'];?></td>
                                    <td class="hidden-480 center">
                                        <?php echo $l['window_contact_phone'];?>
                                    </td>
                                </tr>
                                <?php }?>
                                <?php }else{?>
                                <td colspan="5" class="center"><?php echo $order_date?> 全部档口已全部提交订单</td>
                                
                                <?php }?>
                                </tbody>
                            </table>
                        </div><!-- /.span -->
                    </div><!-- /.row -->
                    
                    
                    <!-- PAGE CONTENT ENDS -->
                </div><!-- /.col -->
            </div><!-- /.row -->
        </div>
    </div>
</block>
<block name="js">
    <script>
        window.onload = function () {
            $('.date-picker').datepicker({
                autoclose: true,
                todayHighlight: true
            })
        }

        function gogogo() {
            var date = $('#id-date-picker-1').val()
            window.location.href = "{:U('Admin/Order/noOrder/')}" + "?order_date=" + date
        }
    
    </script>
</block>
